import 'package:flutter/cupertino.dart';
import 'package:flutter/material.dart';

class IntrinsicWidthDemo extends StatelessWidget{
  @override
  Widget build(BuildContext context) {
    return Scaffold(
      appBar: AppBar(
        title: Text('IntrinsicWidth'),
        centerTitle: true,
      ),
      body: IntrinsicWidth(
        child: Container(
          color: Colors.blue,
          child: Center(
            child: Container(
              color: Colors.red,
              width: 50,
              height: 50,
            ),
          ),
        ),
      ),
    );
  }

}